import random


def generate_test_cases(num_random_cases=20):
    """
    Generates a list of test cases for the maximumSwap function.
    Each test case is a single integer.
    """
    test_cases = []

    # Specific edge and common cases
    test_cases.append(2736)  # Example from problem: 7 to swap with 2 -> 7236
    test_cases.append(9973)  # Example from problem: 9973 -> 9973 (no better swap)
    test_cases.append(10)  # Smallest two-digit: 10 -> 10 (no swap)
    test_cases.append(9)  # Single digit: 9 -> 9 (no swap)
    test_cases.append(98765)  # Already sorted descending: 98765 -> 98765
    test_cases.append(12345)  # Already sorted ascending: 12345 -> 52341 (swap 1 and 5)
    test_cases.append(1993)  # Multiple identical digits: 1993 -> 9913 (swap 1 and rightmost 9)
    test_cases.append(109)  # Swap with a zero: 109 -> 901 (swap 1 and 9)
    test_cases.append(98368)  # Multiple same max digits, swap with rightmost: 98368 -> 98863 (swap 3 and rightmost 8)
    test_cases.append(10000)  # Zeros: 10000 -> 10000
    test_cases.append(120)  # Swap 1 and 2: 220
    test_cases.append(9919)  # Swap 1 and rightmost 9: 9991

    # Generate random cases
    for _ in range(num_random_cases):
        # Random number length between 1 and 9 digits (to keep numbers manageable)
        length = random.randint(1, 9)
        num_str = ''.join([str(random.randint(0, 9)) for _ in range(length)])

        # Ensure multi-digit numbers don't start with '0'
        if length > 1 and num_str[0] == '0':
            num_str = str(random.randint(1, 9)) + num_str[1:]

        test_cases.append(int(num_str))

    return test_cases